]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
appMenuButton: Rename show/hide to fadeIn/fadeOut
authorGeorges Basile Stavracas Neto <georges.stavracas@gmail.com>
Tue, 21 Aug 2018 09:48:19 +0000 (06:48 -0300)
committerGeorges Basile Stavracas Neto <georges.stavracas@gmail.com>
Tue, 9 Oct 2018 01:42:25 +0000 (22:42 -0300)
In the next commit, we will turn PanelMenu.ButtonBox into a
St.Widget subclass. As a domino effect, PanelMenu.Button will
become one too, and so will Panel.AppMenuButton.

When that happens, the current show() and hide() functions in
Panel.AppMenuButton will clash with Clutter.Actor's ones.

To avoid that, rename these functions to fadeIn() and fadeOut()
and avoid a name clash.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/153

js/ui/panel.js

index 27ebec322c632069ec7762575a01de7009c9cce9..b6e831069d6727f71924f0b05059dcbe56bd9cc6 100644 (file)
@@ -149,7 +149,7 @@ var AppMenuButton = new Lang.Class({
         this._sync();
     },
 
-    show() {
+    fadeIn() {
         if (this._visible)
             return;
 
@@ -163,7 +163,7 @@ var AppMenuButton = new Lang.Class({
                            transition: 'easeOutQuad' });
     },
 
-    hide() {
+    fadeOut() {
         if (!this._visible)
             return;
 
@@ -314,9 +314,9 @@ var AppMenuButton = new Lang.Class({
                        shellShowsAppMenu &&
                        !Main.overview.visibleTarget);
         if (visible)
-            this.show();
+            this.fadeIn();
         else
-            this.hide();
+            this.fadeOut();
 
         let isBusy = (this._targetApp != null &&
                       (this._targetApp.get_state() == Shell.AppState.STARTING ||